january 2014 docid022332 rev 2 1/15 AN3991 application note how to drive multiple stepper mo tors with the l6470 motor driver enrico poli introduction the l6470 is a flexible device for the driving of bipolar stepper moto rs in multiple motor systems. this application note describes how to drive three bipolar stepper motors in a daisy chain configuration. each motor position and its velocity can be controlled individually or a sequence of position and ve locity commands can be implemented by using the ironpython scripting language included in the dspin? evaluation tool. with the dspin evaluation tool and steval-pcc009v2 interface board, up to eight stepper motors can be controlled in a daisy chain configuration. www.st.com
contents AN3991 2/15 docid022332 rev 2 contents 1 hardware requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 2 software requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 3 software installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 4 interconnection diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 5 stepper motor characterization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 6 running the motor evalua tion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 7 controlling three motors indivi dually . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 7.1 individual motor position control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 7.2 individual motor speed control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 8 controlling three motors with scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 three_motors script text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 appendix a additional instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 motor back emf constant (ke) measurement . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 9 references . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15 10 revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
docid022332 rev 2 3/15 AN3991 hardware requirements 15 1 hardware requirements each stepper motor being evaluated requires an eval6470h demonstration board. also required is an steval-pcc009v2 interface bo ard that is connected between the pc usb port and the first eval6470h device. a 10-pin flat cable is needed for each eval6470h. a standard usb male to mini usb male cable connects the steval-pcc009v2 to the pc. in addition to the interface boards and cables, a dc power supply with a voltage output between 8 v and 45 v is required.
software requirements AN3991 4/15 docid022332 rev 2 2 software requirements the software needed is the spinfamily eval uation tool which c an be downloaded at www.st.com/dspin. 3 software installation uninstall any previous versions of the dspin evaluation tool. install the dspin evaluation software by clic king on setup windows installer package. after installation is comple te, the dspin software tool is located at c:\program files\stmicroelectronics\ dspin evaluation tool. download the three_motors.py scr ipt from the same page where this application note can be found.
docid022332 rev 2 5/15 AN3991 interconnection diagram 15 4 interconnection diagram with reference to the an3103 application note, on each eval6470h connect the power supply to vs and ground and connect one stepper motor coil to out1a and out2a. connect the other stepper motor coil to out1b and out2b. jumper connections: on the eval6470h, a jumper jp2 is located between the out1a/out2a and out1b/out2b screw connections, just belo w the vdd test point. in the daisy chain connection, jp2 must be open on all eval6470hs except the last one. on the last eval6470h, jp2 is shorted. an add itional eval6470h demonstration boards can be connected in daisy chain mode. up to eight motors can be controlled using a single steval-pcc009v2 interface board. figure 1. daisy chain example to drive two or more boards in daisy chain configuration: 1. open the termination jumpers on all eval6470h demonstration boards except the last one. 2. verify the termination jumper of the last evaluation board is closed. 3. plug the interface board into the pc through the usb cable. 4. if requested, install interface board drivers. 5. connect the interface board 10-pin conn ector to the spi_in connector of the first demonstration board. 6. connect the spi_out connector of the previous demonstration board to the spi_in connector of the next one. 7. repeat item 6 until all the others boards in the chain are connected. information about the termination jumper a nd the spi connectors can be found in the an3103 application note. warning: increasing the number of the devices connected in daisy chain configuration may degrade spi communication performance. if communication issues are found, try to reduce spi clock speed. $ 0 y , q w h u i d f h e r d u g 6 7 ( 9 $ / 3 & |